package com.ws.ssmzongjie3.mapper;

import com.ws.ssmzongjie3.bean.Acl_Role;
import com.ws.ssmzongjie3.bean.Acl_User_Role;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface Acl_User_RoleMapper {
    @Insert("INSERT INTO acl_user_role(user_id,role_id) VALUES(#{user_id},#{role_id})")
    public int insertAcl_User_Role(Acl_User_Role acl_User_Role);
    @Delete("DELETE FROM acl_user_role WHERE user_id = #{user_id}")
    public int deleteAcl_User_Role(Acl_User_Role acl_User_Role);
    @Select("SELECT * FROM acl_user_role WHERE user_id = #{user_id} AND role_id = #{role_id}")
    public Acl_User_Role getAcl_User_RoleById(Acl_User_Role acl_User_Role);

    public void updateAcl_User_Role(Acl_User_Role acl_User_Role);
    public List<Integer> listRole_id(Acl_User_Role acl_User_Role);
    public List<Acl_User_Role> listAcl_User_Role(Acl_User_Role acl_User_Role);
}
